package com.mjf.process_control;

public class ForUse {

    public static void main(String[] args) {

        int[] arr = new int[]{1,2,3,4,5};

        //--增强for循环
        for (int a : arr) {
            System.out.println(a);
        }

        System.out.println("-----------");

        //--普通for循环
        for (int i = 0; i < arr.length; i++) {
            System.out.println(arr[i]);
        }
    }
}
